<template>
	<view class="frame">
		<u-navbar :is-back="true" title="看日志">
			<view slot="right">
				<image src="/static/user/date.png" class="icon" style="margin-right: 32rpx;margin-left: 40rpx;" @click="show = !show" ></image>
			</view>
		</u-navbar>
		<view style="position: fixed;width: 750rpx;z-index: 10;padding: 0rpx 32rpx;background: #FFFFFF;">
		 <u-tabs :list="tabList" style="margin-top: 18rpx;" :is-scroll="false" active-color="#0052D9" inactive-color="#858A99" :current="current" 
		 @change="change"></u-tabs>
		</view>
		<view style="width: 750rpx;height: 100rpx;"></view>
		<scroll-view id="scrollview" class="chat-window" scroll-y="true" :style="{height: (clientHeight-80) + 'px'}"
		:scroll-with-animation="scrollAnimation">
		<view class="frame-content" v-for="(item,index) in list" :key="index" @click="go('/pages5/log/logDetail')">
			<view style="display: flex;">
				<image :src="avatar" class="img" ></image>
				<view style="margin-left: 24rpx;">
					<view class="frame-text" style="margin-top: 4rpx;">张三的工作日志</view>
					<view class="frame-time">2024-08-15  10:00</view>
				</view>
			</view>
			<view style="margin-top: 30rpx;">
				<view class="frame-conent text-1 text-2">任务名称:测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本</view>
				<view class="frame-conent text-1 text-2">问题描述:测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本</view>
				<view class="frame-conent text-1 text-2">解决方案:测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本</view>
				<view class="frame-conent text-1 text-2">心得体会:测试文本测试文本测试文本测试文本测试文本测试文本测试文本测试文本</view>
			</view>
		</view>
		</scroll-view>
		<view class="frame-buttom flexcen">
			<view class="button flexcen">写日志</view>
		</view>
		<!-- 日期选择器 -->
		<u-picker mode="time" v-model="show" :params="params" @confirm="dateConfirm"></u-picker>
		<!-- 电话提示滑动快 -->
		<movablearea1 :movaheight="movaheightAll" v-if="movableareaShow" @editMovaheightAll="editMovaheightAll" :movaTop="movaTopAll"></movablearea1>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				tabList:[{
					name: '我收到的'
				}, {
					name: '我发出的'
				}],
				current:0,
				avatar:'https://cdn.uviewui.com/uview/album/1.jpg',
				list:[1,2],
				scrollAnimation:true,
				show:false,
				params: {
					year: true,
					month: true,
					day: true,
					hour: false,
					minute: false,
					second: false
				},
			}
		},
		methods: {
			change(e){
				this.current = e
			},
			// 日期选择反馈
			dateConfirm(e){
				console.log('e',e)
			}
		}
	}
</script>

<style lang="less">
	.icon{
		width: 41rpx;
		height: 41rpx;
	}
	.frame{
		background: #F3F4F6;
	}
	.frame-content{
		margin-top: 16rpx;
		padding: 32rpx;
		background: #FFFFFF;
	}
	.img{
		width: 80rpx;
		height: 80rpx;
		border-radius: 50%;
	}
	.frame-text{
		font-weight: 500;
		font-size: 32rpx;
		color: #333333;
	}
	.frame-time{
		font-weight: 400;
		font-size: 24rpx;
		color: #878787;
	}
	.frame-conent{
		// margin-top: 10rpx;
		line-height: 45rpx;
		font-weight: 400;
		font-size: 28rpx;
		color: #333333;
	}
	.chat-window{
		// background: #000;
	}
	.frame-buttom{
		position: fixed;
		bottom: 0rpx;
		width: 750rpx;
		height: 120rpx;
		background: #FFFFFF;
		box-shadow: 0rpx -2rpx 6rpx 1rpx rgba(0,0,0,0.16);
		border-radius: 0rpx 0rpx 0rpx 0rpx;
	}
	.button{
		width: 686rpx;
		height: 80rpx;
		background: #0052D9;
		border-radius: 15rpx 15rpx 15rpx 15rpx;
		font-size: 30rpx;
		color: #FFFFFF;
		font-weight: normal;
	}
</style>
